package com.tensquare.qa.client;

import com.tensquare.base.pojo.Label;
import com.tensquare.qa.client.impl.LabelClientFallBack;
import entity.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;

/**
 * @author Macross
 * @Type LabelClient.java
 * @Desc
 * @date 2019/12/25 16:28
 */
@FeignClient(name = "tensquare-base",fallback = LabelClientFallBack.class)
public interface LabelClient {

    /**
     * 通过id获取标签信息【远程调用tensquare-base模块的方法】
     * @param id 标签id
     * @return
     */
    @PostMapping("/label/{id}")
    Result<Label> findById(@PathVariable("id") String id);
}
